package com.erb.service.cgs;

import com.erb.entity.*;
import org.apache.ibatis.annotations.Param;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;
import java.util.Map;

public interface SmloadService {
	Apply Selectstate(int uid, String loantype, int applyid);

	//查询用户所有的申请
	List<Apply> selectapply(int uid, String applyid);

	void updusermoney(int id,double money);

	void AddSmloan(Apply apply);

	//查询用户所有的贷款
	List<Loan> selectloan(int uid);

	//查询用户还贷款
	List<Loan> selectpayloan(int uid, int agree);

	//还款
	Loan payloan(int lid);

	//查询所有贷款信息
	List<Loan> allloan();

	//添加贷款信息
	int addpayloan(int payint, Payloan payloan);

	//查看合同
	Loan hetongloan(int lid, String loantype);

	//查看当前月份是否有要还款的信息
	Payloan loaning(int lid);

	//下棋还款日
	int paydate(int lid);

	//查询贷款信息
	List<Payloan> paylist(int lid);

	//查询未还贷款信息
	List<Payloan> nopaylist(int lid, int paystate);

	//修改贷款信息
	int updatepay(Payloan payloan);

	//修改贷款信息
	int updatepayall(Payloan payloan);

	//查询贷款信息
	int updateloan(double repayment, int lid);

	List<Apply> applylist();

	//获取uid
	Apply seluid(int id);

	//查询车辆信息
	List<Carimf> carlists(int id);

	//查询房产信息
	List<Houseimf> Houselist(int id);

	//查询公积金
	List<Publicimf> publiclist(int id);

	//查询保险
	List<Insuranceimf> insurancelist(int id);

	//修改审核状态
	void updApply(int state, int id);

	//查询总行数
	int selProcount();

	//分页查询数据
	List<Apply> selApplyPage(Pager Pager);

	void addloansubmit(Loan loan);

	Loan loanState(int uid, String loantype, int applyid);

	//添加公积金资料
	void addpubliceimf(Publicimf publicimf);

	//添加车辆信息
	void addcarimf(Carimf carimf);

	//查询所有车辆
	List<Map> selectcarimf(int uid);


	//添加房子信息
	void addhouseimf(Houseimf houseimf);

	//查询所有房
	List<Map> selecthouseimf(int uid);

	String proimg(MultipartFile file);

	List<Map> carisnull(String caridcard);

	List<Map> houseisnull(String housedata);

	Publicimf selectpublic(int uid);


	//添加保险
	void addinsuranceimf(Insuranceimf insuranceimf);

	//查看保险
	Insuranceimf selectinsuranceimf(int uid);

	//查询用户拥有的机动车驾驶证
	List<Map> selectcarimf_user(int uid, int carowner);

	//修改车辆
	void updatecarimf_user(int caridcard, int carapplyid);

	//修改房主
	void updatehouseimf_user(int houseid, int houseapplyid);

	//查询抵押所有车辆
	List<Map> diyacarimf(int uid, int carapplyid, int carowner);

	//查询抵押所有房
	List<Map> diyahouserimf(int uid, int houseapplyid, int houseowner);

	int updateuser(int id, Double money);

	int updateuserlimit(int id, Double money);

}
